package cn.sofwin.mc.sb.config;

import cn.sofwin.mc.sb.entity.JDBC;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;

@Configuration
@PropertySource("classpath:company.properties")
public class AppConfig {
     @Value("${username}")
    private String username;

    @Bean
    public JDBC jdbc(){
        JDBC jdbc = new JDBC();
        jdbc.setUsername(username);
        return jdbc;

    }
}
